import { createApp } from 'vue'
import { createPinia } from 'pinia'
import piniaPersist from 'pinia-plugin-persist'

import App from './App.vue'
import router from './router'

import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import 'element-plus/theme-chalk/dark/css-vars.css'

import 'virtual:svg-icons-register'
import SvgIcon from '@/components/SvgIcon/index.vue'
import zhCn from 'element-plus/es/locale/lang/zh-cn'
import 'dayjs/locale/zh-cn'
// element图标

import '@/styles/index.scss'
const pinia = createPinia()
pinia.use(piniaPersist)
const app = createApp(App)
app.component('SvgIcon', SvgIcon)

app.use(pinia)
app.use(ElementPlus, { size: 'default', locale: zhCn })
app.use(router)

app.mount('#app')
